<template>
  <van-swipe class="my-swipe" :autoplay="3000" indicator-color="white">
    <van-swipe-item v-for="item in banner" :key="item.id">
      <img :src="item.url" alt="">
    </van-swipe-item>
  </van-swipe>
</template>

<script setup>
import { defineProps } from 'vue';
const props = defineProps({
  banner: {
    type: Array,
    default: () => []
  }
})
</script>

<style scoped lang="scss">
.my-swipe .van-swipe-item {
  color: #fff;
  font-size: 20px;
  text-align: center;
}
.van-swipe-item {
  > img {
    width: 100%;
  }
}
</style>
